home *** CD-ROM | disk | FTP | other *** search
- On 25-Oct-97, Alastair Murray wrote:
- >Anyone have any AMOS code for doing a pattern match on a string?
- >e.g. *.AMOS or #?.AMOS to see if a string contains .AMOS in it
- >anywhere.
- >Saves me writing it myself...
-
- A=Instr(<string to check>,<string to search for>)
-
- If it was there, A will contain the start position of the first occurance.
- Otherwise, A will be 0.
-
- Well met and godspeed,
- Giark
- joehick@golden.net
- http://www.golden.net/~joehick/fbn/index.html
- ______ ______ _____ .------------------------------------------.
- / ____/ / __ / / ___ \ ! AMOS games, utilities, demos, etc. !
- / /__ / /_/ / / / / / ! !
- / ___/ / ___ | / / / / ! CyberSpace BBS (519)579-0072 !
- / / / /__/ / / / / / ! on A2000 060/50MHz (519)579-0173 !
- /_/ /______/ /_/ /_/ ! !
- Fly By Nite Videe-Oh! ! FBN Amiga 500 020 14MHz 1C/5F RAM 3.1OS !
- IAPA Member `------------------------------------------'
-
-
-